package com.chat.api.web.vo;

import com.chat.api.utils.util.DateUtil;
import com.chat.api.utils.util.ParamUtil;
import com.chat.api.web.po.ApprovalBean;
import com.chat.api.web.po.BlogBean;
import lombok.Data;
import java.io.Serializable;
import java.util.Date;

@Data
public class ApprovalEntity implements Serializable {
    private static final long serialVersionUID = 1L;

    private String id;
    private String name;
    private String iphone;
    private String email;
    private String job;
    private Integer score;//评分
    private Integer level;
    private Date startTime;
    private Date endTime;
    private Integer isInner;//是否内推
    private String procInstId;//流程实例id
    private String initiator;//发起人
    private String approver;//审批人

    private String user;//下一节点执行人
    private Integer result;//审批结果
    private String flowNodeName;//待办流程节点名称

    public void setBean(ApprovalBean bean){
        bean.setId(Long.valueOf(id));
        bean.setName(name);
        bean.setIphone(iphone);
        bean.setEmail(email);
        bean.setJob(job);
        bean.setScore(score);
        bean.setLevel(level);
        bean.setStartTime(startTime);
        bean.setEndTime(endTime);
        bean.setProcInstId(procInstId);
        bean.setIsInner(isInner);
    }

    public void setValue(ApprovalBean bean){
        this.setId(String.valueOf(bean.getId()));
        this.setName(bean.getName());
        this.setIphone(bean.getIphone());
        this.setEmail(bean.getEmail());
        this.setJob(bean.getJob());
        this.setScore(bean.getScore());
        this.setLevel(bean.getLevel());
        this.setStartTime(startTime);
        this.setEndTime(endTime);
        this.setProcInstId(bean.getProcInstId());
        this.setIsInner(bean.getIsInner());
    }

}
